package com.cxl.price.bean;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;

import com.summer.core.common.BeanName;
import com.summer.core.entity.BaseBean;

@Entity
@BeanName("产品 型号")
public class Model extends BaseBean{
	private static final long serialVersionUID = -1436591707002343129L;

	private Brand brand;//所属品牌
	
	private Long pid;
	
	private Long vid;
	
	private String name;

	@ManyToOne(cascade=CascadeType.REFRESH,fetch = FetchType.LAZY)
	@JoinColumn(name = "brand_id")
	public Brand getBrand() {
		return brand;
	}

	public void setBrand(Brand brand) {
		this.brand = brand;
	}

	public Long getPid() {
		return pid;
	}

	public void setPid(Long pid) {
		this.pid = pid;
	}

	public Long getVid() {
		return vid;
	}

	public void setVid(Long vid) {
		this.vid = vid;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

}
